<template>
  <div>
    <div class="Logout">
      <Logout>退出</Logout>
    </div>
    <h1>仓储缴费</h1>
    <el-row>
      公司id:<el-input style="width: 500px" size="medium" v-model="sno" placeholder="请输入你公司的id" prefix-icon="el-icon-s-custom" maxlength="10" show-word-limit clearable></el-input>
    </el-row>
    <el-row>
      仓库id:<el-input style="width: 500px" size="medium" v-model="cno" placeholder="请输入你的入库号" prefix-icon="el-icon-price-tag" maxlength="10" show-word-limit clearable></el-input>
    </el-row>
    <el-row>
      仓储费:<el-input style="width: 500px" size="medium" v-model="aamount" placeholder="请输入存储的费用" prefix-icon="el-icon-money" maxlength="10" show-word-limit clearable></el-input>
    </el-row>
    <el-row>
      <el-button @click="pay" type="danger" icon="el-icon-sell">支付</el-button>
    </el-row>
  </div>
</template>

<script>
import Logout from "./Logout";
export default {
  name: "Pay",
  components:{Logout},
  data() {
    return {
      sno:'',
      cno:'',
      aamount:'',
    }
  },
  methods: {
    pay(){
      let parmas = {
        sno:this.sno,
        cno:this.cno,
        aamount:this.aamount,
      }
      this.$axios.post(`/Pay`, parmas).then((res) => {
        console.log(res);
        if("支付成功" === res.data.msg){
          alert("缴费成功");
        }else{
          alert(res.data.msg);
        }
      });
    }
  }
}
</script>

<style scoped>

</style>
